import {EnoadBaseModule} from "../../index";
import { v4 as uuidv4 } from 'uuid';

export default class DataResource extends EnoadBaseModule {
  constructor(config: string) {
    super(config);
  }

  getData() {
    let length = this.config.length;
    let data = [];
    for (let index = 0; index < length; index++) {
      data.push({
        uuid: uuidv4(),
        id: index,
        name: "测试数据" + index,
      });
    }
    return data;
  }

  getURL() {
    return "";
  }
}
